home *** CD-ROM | disk | FTP | other *** search
- #include <exec/types.h>
- #include <exec/ports.h>
- #ifdef __GNUC__
- #define BASE_EXT_DECL
- #define BASE_NAME (*(void **)4)
- #include <inline/exec.h>
- #endif
-
- void
- DeletePort(port)
- struct MsgPort *port;
- {
- if ( port->mp_Node.ln_Name ) /* if it was public */
- RemPort(port);
-
- /* make it difficult to reuse the port */
- port->mp_SigTask = (struct Task *)-1;
- port->mp_MsgList.lh_Head = (struct Node *)-1;
-
- FreeSignal(port->mp_SigBit);
-
- FreeMem(port, sizeof(*port));
- }
-